<template>
  <el-col :span="12">
    <el-form-item
      label="附件"
      prop="files"
      :rules="[{ required: true, message: '请上传附件', trigger: 'change' }]"
    >
      <OproUpload2
        v-model="form.files"
        modelCode="PLAN_sign_exec"
        modelName="开票"
        listType="text"
        @change="handleFileChange"
      >
        <template #tip>
          <div class="el-upload__tip">
            支持格式：.rar .zip .doc .docx .pdf ，单个文件不能超过20MB
          </div>
        </template>
      </OproUpload2>
    </el-form-item>
  </el-col>
</template>

<script setup name="ProjectSettle">
import OproUpload2 from "@/views/components/OproUpload2";


const form = reactive({
  id: null,
  contractId: "",
  files: null,
});

function handleFileChange(val) {
  formRef.value?.validateField("files");
}

</script>